<template>
  <button @click="fu1">点击一下</button>
</template>

<script>
export default {
    // name:'MyButton',
    methods: {
        fu1: function() {
            alert(123)
        }
    }
}
</script>

<style>
    button{
        border: none;
        color: #fff;
        background: skyblue;
        padding: 5px 10px;
    }
</style>